package org.jeecg.modules.rental.enums;

import org.jeecg.common.annotation.EnumDict;
import org.jeecg.common.enums.IEnumDict;
import org.jeecg.common.exception.JeecgBootException;

@EnumDict(code ="deposit_status_dict", name = "账户套餐押金状态枚举")
public enum DepositStatusEnums implements IEnumDict<DepositStatusEnums> {

    UNRETURN_DEPOSIT("0", "未退押金"),

    REFUNDED_DEPOSIT("1", "已退押金"),

    REVIEW_DEPOSIT("2", "审核中");
    private String value;

    private String label;

    DepositStatusEnums(String value, String label) {
        this.value = value;
        this.label = label;
    }

    @Override
    public String getValue() {
        return value;
    }

    @Override
    public String getLabel() {
        return label;
    }

    @Override
    public String getKey() {
        return value;
    }

    @Override
    public String getRemark() {
        return null;
    }

    public static DepositStatusEnums getEnumByValue(String value){
        for(DepositStatusEnums item: values()){
            if(value.equals(item.value)){
                return item;
            }
        }
        throw new JeecgBootException("没找到对应字典");
    }

}
